/**
 * Copyright &copy; 2016-2017 <a href="http://git.oschina.net/whoamien/backend_management">Backend Management</a> All rights reserved.
 */
package com.xw.util;

import org.springframework.util.ReflectionUtils;

/**
 * The Class BeanUtils.
 *
 * @author Xi Wei
 */
public class BeanUtils {

	private static void handleReflectionException(Exception e) {
		ReflectionUtils.handleReflectionException(e);
	}

	/**
	 * Copy properties.
	 *
	 * @param dest the dest
	 * @param orig the orig
	 */
	public static void copyProperties(Object dest, Object orig) {
		try {
			org.apache.commons.beanutils.BeanUtils.copyProperties(dest, orig);
		} catch (Exception e) {
			handleReflectionException(e);
		}
	}
}
